/* 拖拽预览框 */
.dragPreview {
  position: fixed;
  z-index: 10000;
  background: rgba(255, 255, 255, 0.95);
  border: 2px solid;
  border-radius: 6px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(8px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  pointer-events: none;
  transform: rotate(2deg);
  animation: dragFloat 0.3s ease-out;
}

@keyframes dragFloat {
  from {
    transform: scale(1) rotate(0deg);
    opacity: 0.8;
  }
  to {
    transform: scale(1.05) rotate(2deg);
    opacity: 0.95;
  }
}

.dragPreview.validDrop {
  border-color: #4caf50;
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.1), rgba(46, 125, 50, 0.1));
}

.dragPreview.invalidDrop {
  border-color: #f44336;
  background: linear-gradient(135deg, rgba(244, 67, 54, 0.1), rgba(211, 47, 47, 0.1));
}

.roomNumber {
  font-weight: bold;
  font-size: 12px;
  color: #333;
  margin-bottom: 2px;
}

.roomType {
  font-size: 9px;
  color: #666;
  text-align: center;
  line-height: 1.2;
}

.dragIcon {
  position: absolute;
  top: -8px;
  right: -8px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: bold;
  color: white;
}

.validDrop .dragIcon {
  background: #4caf50;
}

.invalidDrop .dragIcon {
  background: #f44336;
}

/* 拖拽提示工具条 */
.dragTooltip {
  position: fixed;
  z-index: 10001;
  pointer-events: none;
  animation: tooltipFadeIn 0.2s ease-out;
}

@keyframes tooltipFadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.tooltipContent {
  background: rgba(0, 0, 0, 0.9);
  color: white;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 11px;
  line-height: 1.4;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(8px);
  max-width: 250px;
}

.sourceInfo {
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.targetInfo {
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 3px 6px;
  border-radius: 4px;
}

.targetInfo.validTarget {
  background: rgba(76, 175, 80, 0.2);
  border: 1px solid rgba(76, 175, 80, 0.5);
}

.targetInfo.invalidTarget {
  background: rgba(244, 67, 54, 0.2);
  border: 1px solid rgba(244, 67, 54, 0.5);
}

.errorReason {
  font-size: 10px;
  color: #ffab91;
  margin-top: 2px;
  font-style: italic;
}

.instructions {
  font-size: 10px;
  color: #ccc;
  text-align: center;
  margin-top: 4px;
  font-style: italic;
}

/* 拖拽遮罩 */
.dragOverlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.02);
  backdrop-filter: blur(1px);
  pointer-events: none;
}

/* 响应式适配 */
@media (max-width: 768px) {
  .dragPreview {
    transform: rotate(1deg) scale(0.9);
  }
  
  .tooltipContent {
    font-size: 10px;
    padding: 6px 10px;
    max-width: 200px;
  }
  
  .roomNumber {
    font-size: 11px;
  }
  
  .roomType {
    font-size: 8px;
  }
}

/* 暗色主题支持 */
@media (prefers-color-scheme: dark) {
  .dragPreview {
    background: rgba(45, 55, 72, 0.95);
    color: #e2e8f0;
  }
  
  .roomNumber {
    color: #e2e8f0;
  }
  
  .roomType {
    color: #a0aec0;
  }
  
  .tooltipContent {
    background: rgba(26, 32, 44, 0.95);
  }
}

/* 拖拽动画效果 */
.dragPreview:hover {
  animation: dragPulse 1s ease-in-out infinite alternate;
}

@keyframes dragPulse {
  from {
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  }
  to {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
  }
}

